package cn.kbyue.exceptiondemo.common.validate;

import javax.validation.Constraint;
import javax.validation.Payload;
import java.lang.annotation.*;

/**
 * @author xlang
 * @date 2023/4/4 13:08
 */
@Target(ElementType.TYPE)
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Constraint(validatedBy = DateSequenceCheckValidator.class)
public @interface DateSequenceCheck {

    // 默认错误信息
    String message() default "开始时间不能晚于结束时间";

    // 分组
    Class<?>[] groups() default {};

    // 负载
    Class<? extends Payload>[] payload() default {};

}
